Function Subspace :: _rs literal
Constructs an isize
range from a literal.
The constructed range satisfies the RangeBounds<isize>
concept. Numbers may be positive or negative.
The syntax is a string (in double quotes) containing:
start..end
for a range including start and excluding end. This returns asus::ops::Range<isize>
.start..=end
for a range including start and including end. This returns asus::ops::Range<isize>
.start..
for a range including start and never ending. This returns asus::ops::RangeFrom<isize>
...end
for a range including everything up end. This returns asus::ops::RangeTo<isize>
...=end
for a range including everything up and including end. This returns asus::ops::RangeTo<isize>
...
for a range that has no bounds at all. Typically for a slicing range to indicate the entire slice. This returns asus::ops::RangeFull<isize>
.
Examples
sus_check("1..4"_rs).start == 1);
sus_check(("1..4"_rs).finish == 4);
sus_check(("1..=4"_rs).finish == 5);